package com.bocom.test;

import com.gargoylesoftware.htmlunit.WebClient;
import com.gargoylesoftware.htmlunit.html.HtmlPage;

public class opendoor {	
	
	public static void dooropen() throws Exception {
	    final WebClient webClient = new WebClient();
	    //1.获取某个待测页面
	    final HtmlPage page2 = webClient.getPage("http://10.192.165.45:1982/api/Led/DoorControl?"
	    		+ "devicetype=hik&ip=10.192.165.244&port=8000&user=admin&passwd=12345&time=3");
	    
	    System.out.println(page2.getBaseURI());
	    
	    webClient.closeAllWindows();
	    
	}		
	
	public static void main(String[] args) {

		try {
			for(int i=1;i<=10000;i++){
				dooropen();
				System.out.println("i:="+i);
			}
			
			
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
}
